<%@page import="java.util.ArrayList"%>
<%@page import="java.util.HashMap"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%
   out.clear();
   out = pageContext.pushBody(); 
    response.setContentType("image/jpeg");  
   NWDB.NWDB mydb=new NWDB.NWDB();
   NWDB.IProduct pp=new NWDB.ImplProduct(mydb.getConnection());
   mydb.setIProduct(pp);
   //int productId=10;
   int productId=Integer.parseInt(request.getParameter("pid"));   
    int pic=Integer.parseInt(request.getParameter("pp"));   
  HashMap<String, Object> res= mydb.GetProductImageById_4pic(productId);
  byte[] bb =(byte[]) res.get("產品圖片_"+pic);  
   mydb.close();
   response.getOutputStream().write(bb);
%>